package com.bupt.liutong.front.sch.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

import com.bupt.liutong.admin.core.base.BaseAction;
import com.bupt.liutong.admin.sch.bo.AlbumBo;
import com.bupt.liutong.admin.sch.form.AlbumForm;

public class AlbumAction extends BaseAction {

	private AlbumBo albumBo;

	public ActionForward list(ActionMapping mapping,
			ActionForm form, HttpServletRequest request,
			HttpServletResponse response) {
		AlbumForm albumForm = (AlbumForm) form;
		albumForm.setPageSize(15);
		request.setAttribute("albumFormList", albumBo.getAlbumsByPage(
				albumForm, request));
		putPageInfo(request, albumForm);
		return mapping.findForward("list");
	}

	public void setAlbumBo(AlbumBo albumBo) {
		this.albumBo = albumBo;
	}
}
